package com.ruoyi.system.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 消息管理对象 chat_message
 * 
 * @author ruoyi
 * @date 2024-11-27
 */
public class ChatMessage extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** $column.columnComment */
    private Long id;

    /** 发送者ID */
    @Excel(name = "发送者ID")
    private Long fromUserId;

    /** 接收者ID */
    @Excel(name = "接收者ID")
    private Long toUserId;

    /** 消息内容 */
    @Excel(name = "消息内容")
    private String content;

    /** 消息类型：1-文本 2-图片 3-商品链接 */
    @Excel(name = "消息类型：1-文本 2-图片 3-商品链接")
    private Long msgType;

    /** 关联商品ID */
    @Excel(name = "关联商品ID")
    private Long goodsId;

    /** 读取状态：0-未读 1-已读 */
    @Excel(name = "读取状态：0-未读 1-已读")
    private Long readStatus;

    /** 是否删除 */
    @Excel(name = "是否删除")
    private Long deleted;

    public void setId(Long id) 
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setFromUserId(Long fromUserId) 
    {
        this.fromUserId = fromUserId;
    }

    public Long getFromUserId() 
    {
        return fromUserId;
    }
    public void setToUserId(Long toUserId) 
    {
        this.toUserId = toUserId;
    }

    public Long getToUserId() 
    {
        return toUserId;
    }
    public void setContent(String content) 
    {
        this.content = content;
    }

    public String getContent() 
    {
        return content;
    }
    public void setMsgType(Long msgType) 
    {
        this.msgType = msgType;
    }

    public Long getMsgType() 
    {
        return msgType;
    }
    public void setGoodsId(Long goodsId) 
    {
        this.goodsId = goodsId;
    }

    public Long getGoodsId() 
    {
        return goodsId;
    }
    public void setReadStatus(Long readStatus) 
    {
        this.readStatus = readStatus;
    }

    public Long getReadStatus() 
    {
        return readStatus;
    }
    public void setDeleted(Long deleted) 
    {
        this.deleted = deleted;
    }

    public Long getDeleted() 
    {
        return deleted;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("fromUserId", getFromUserId())
            .append("toUserId", getToUserId())
            .append("content", getContent())
            .append("msgType", getMsgType())
            .append("goodsId", getGoodsId())
            .append("readStatus", getReadStatus())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .append("deleted", getDeleted())
            .toString();
    }
}
